import { defineStore } from 'pinia';
import {getTypeList} from '@/api/api.js';
import {ref} from 'vue'
export const useTypeStore = defineStore('type', () => {
	const payType = ref({});
	const inType = ref({})
   async function getData() {
		 const list = (await getTypeList()).list;
		 payType.value = list.filter(item => item.type==0)
		 inType.value = list.filter(item => item.type==1)
    }
	return { payType, inType,getData };
});
